package com.lmaye.design.patterns.creation.prototype.deepclone;

import java.io.Serializable;

/**
 * -- Cat
 *
 * @author lmay.Zhou
 * @date 2020/11/18 23:59 星期三
 * @qq 379839355
 * @email lmay@lmaye.com
 * @since JDK1.8
 */
public class Cat implements Cloneable, Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * name
     */
    private String name;

    public Cat() {

    }

    public Cat(String name) {
        this.name = name;
    }

    @Override
    protected Object clone() throws CloneNotSupportedException {
        return super.clone();
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Override
    public String toString() {
        return "Cat{" +
                "name='" + name + '\'' +
                '}';
    }
}
